<!doctype html>


<html>
<head>
  <link rel="shortcut icon" href="static/images/favicon.ico" type="image/x-icon">
  <title>XmlHttp_ (Closure Library API Documentation - JavaScript)</title>
  <link rel="stylesheet" href="static/css/base.css">
  <link rel="stylesheet" href="static/css/doc.css">
  <link rel="stylesheet" href="static/css/sidetree.css">
  <link rel="stylesheet" href="static/css/prettify.css">

  <script>
     var _staticFilePath = "static/";
  </script>

  <script src="static/js/doc.js">
  </script>

  <meta charset="utf8">
</head>

<body onload="prettyPrint()">

<div id="header">
  <div class="g-section g-tpl-50-50 g-split">
    <div class="g-unit g-first">
      <a id="logo" href="index.html">Closure Library API Documentation</a>
    </div>

    <div class="g-unit">
      <div class="g-c">
        <strong>Go to class or file:</strong>
        <input type="text" id="ac">
      </div>
    </div>
  </div>
</div>





<div class="colmask rightmenu">
<div class="colleft">
    <div class="col1">
      <!-- Column 1 start -->

<div id="title">
        <span class="fn">ds.XmlHttp_</span>
        <span>Extends</span>
        <span class="fn-name">
          <a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">
            Object</a>
        </span>
</div>

<div class="g-section g-tpl-75-25">
  <div class="g-unit g-first" id="description">
    XMLHttp utilities based of Prototype
Temporary until closure libraries are complete
TODO move to common xmlhttp when libraries are complete

Build an XmlHttp object
  </div>


        <div class="g-unit" id="useful-links">
          <div class="title">Useful links</div>
          <ol>
            <li><a href="closure_goog_datasource_xmldatasource.js.source.html"><span class='source-code-link'>Source Code</span></a></li>
          </ol>
        </div>
</div>






<h2 class="g-first">Inheritance</h2>
<pre class="inheritance">
Object
     <img src="static/images/inherit.gif">goog.ds.XmlHttp_
</pre>




  <h2>Constructor</h2>
      <div class="fn-constructor">
    goog.ds.XmlHttp_(<span><span class="arg">uri</span>,&nbsp;<span class="arg">onload</span>,&nbsp;<span class="arg">opt_onerror</span></span>)
  </div>

   <h3>Parameters</h3>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">uri</span>
        : <div class="fullType"><span class="type">(string,goog.Uri)</span></div>
        <div class="entryOverview">The URL to send to.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">onload</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span></div>
        <div class="entryOverview">Function to call when xml document loads succesfully.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_onerror</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span></div>
        <div class="entryOverview">Function to call when xml document load fails.</div>
     </td>
   </tr>
  </table>


<h2>Instance Methods</h2>


  <div class="legend">
        <span class="key publickey"></span><span>Public</span>
        <span class="key protectedkey"></span><span>Protected</span>
        <span class="key privatekey"></span><span>Private</span>
  </div>







<div>
       <div class="desc">
         Defined in
         <span class="fn-name">
            <a href="class_goog_ds_XmlHttp_.html">
              goog.ds.XmlHttp_
            </a>
         </span>
       </div>






<div class="section">
  <table class="horiz-rule">


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.getRequest"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">getRequest<span class="args">()</span>
        </span>
        &#8658; <div class="fullType"><span class="type">goog.net.XmlHttp</span></div>
      </div>


     <div class="entryOverview">
       Default error function if none is passed in
     </div>


    <! -- Method details -->
    <div class="entryDetails">

   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type">goog.net.XmlHttp</span></div>&nbsp;
            the XMLHttpRequest.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line497">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.handleDefaultError_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">handleDefaultError_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       Default error function if none is passed in
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line488">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.loadXmlDoc_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">loadXmlDoc_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       Load the xml document
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line424">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.onError_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">onError_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       Onload and onerror set a timeout to call the real functions
to get around threading issues
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line479">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.onLoad_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">onLoad_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       Onload and onerror set a timeout to call the real functions
to get around threading issues
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line469">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>






  <td>
    <a name="goog.ds.XmlHttp_.prototype.onReadyStateChange_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryName">onReadyStateChange_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       Callback when status changes occur in request
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_datasource_xmldatasource.js.source.html#line445">code &raquo;</a>
  </td>
     </tr>


  </table>
</div>
</div>




















<div class="section">
  <table class="horiz-rule">


  </table>
</div>









<div class="section">
  <table class="horiz-rule">


  </table>
</div>
      <!-- Column 1 end -->
    </div>

        <div class="col2">
          <!-- Column 2 start -->
          <div class="col2-c">
            <h2 id="ref-head">Package ds</h2>
            <div id="localView"></div>
          </div>

          <div class="col2-c">
            <h2 id="ref-head">Package Reference</h2>
            <div id="sideTypeIndex" rootPath="goog" current="ds.XmlHttp_"></div>
          </div>
          <!-- Column 2 end -->
        </div>
</div>
</div>

</body>
</html>
